/***************************************************************************
 创建者：       hualei
 开始时间：    2018.09.10
 copyright:(C) 深圳市华友高科有限公司
 修改说明：（每次有修改就添加一条，带有 修改人，修改时间，修改描述）

 ***************************************************************************/
#include "odometryinstructiondelegate.h"
#include <QDebug>

OdometryInstructionDelegate::OdometryInstructionDelegate(QWidget *parent)
    : QWidget(parent)
{
}

void OdometryInstructionDelegate::initView()
{
    odometryInstructionView->posX = 0.000;
    odometryInstructionView->posY = 0.000;
    odometryInstructionView->posR = 0.000;
    odometryInstructionView->noteStr = "No Note!";

}

void OdometryInstructionDelegate::finishEditInstructionSlot()
{
    odometryInstructionView->instructionOut = tr("SET_ODOM ");
    odometryInstructionView->instructionOut += QString::number(odometryInstructionView->posX) + "," + QString::number(odometryInstructionView->posY);
    odometryInstructionView->instructionOut += "," + QString::number(odometryInstructionView->posR) + "  //" + odometryInstructionView->noteStr;
}

void OdometryInstructionDelegate::cleanNoteSlot()
{
    odometryInstructionView->noteStr.clear();

    qDebug() << "Clean The Note!";
}
